package swb.api.com.service;

import org.springframework.data.domain.Page;
import swb.api.com.repository.dto.WithdrawAccount;
import swb.api.com.repository.dto.WithdrawRecord;
import swb.api.com.vo.resp.WithdrawResponse;

import java.math.BigDecimal;
import java.util.List;

/**
 * 提现服务接口
 */
public interface WithdrawService {

    /**
     * 发起提现申请
     *
     * @param userId 用户ID
     * @param accountId 账户ID
     * @param amount 提现金额
     * @return 提现响应
     */
    WithdrawResponse applyWithdraw(Long userId, Long accountId, BigDecimal amount);

    /**
     * 查询用户提现记录
     *
     * @param userId 用户ID
     * @param status 状态筛选(可选)
     * @param page 页码
     * @param size 每页数量
     * @return 提现记录列表
     */
    Page<WithdrawRecord> getWithdrawRecords(Long userId, Integer status, int page, int size);

    /**
     * 查询提现详情
     *
     * @param recordId 提现记录ID
     * @return 提现记录详情
     */
    WithdrawRecord getWithdrawRecordDetail(Long recordId);

    /**
     * 获取用户默认提现账户
     *
     * @param userId 用户ID
     * @return 默认提现账户
     */
    WithdrawAccount getDefaultAccount(Long userId);
}
